import { AuthService } from './auth.service';
import {
  Body,
  Controller,
  HttpCode,
  HttpStatus,
  Post
} from '@nestjs/common';
import { AuthGuard } from '../guard/auth/auth.guard';
import { Public } from '../decorator/is-public/is-public.decorator';

@Controller('auth')
export class AuthController {
  constructor(private readonly authService: AuthService) {}
  @Public()
  @Post('login')
  @HttpCode(HttpStatus.OK)
  login(@Body() authDto: Record<string, any>) {
    return this.authService.signIn(authDto.username, authDto.password);
  }
}

@Controller('mobile/auth')
export class MobileAuthController {}
